package com.yning.coroutines

import java.text.Format
import java.text.SimpleDateFormat
import java.util.*

object Log{
    fun d(log: Any){
        val date : Date = Date()
        println("${date.getCurrentDate(date)} [${Thread.currentThread().name}]  $log")
    }
}

fun Date.getCurrentDate(mDate : Date):String{
    val sdf : Format = SimpleDateFormat("yyyy-MM-dd HH:mm:ss")
    return sdf.format(mDate)
}